<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<%@taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>流程定义列表</title>
</head>
<body>
sss
<div id="defListDiv">
<table id="defListTable">

</table>
</div>
<script type="text/javascript">
$(function(){
	
	$("#defListTable").datagrid({
		width : 'auto',
		height : 'auto',
		url : 'workFlow/getDefinitionList',
		queryParams : {},
		rownumbers : false,
		pagination : false,
		pageSize : 10,
		pageList : [ 10, 20, 50 ],
		pageNumber : 1,
		// nowrap:false与word-break:break-all用于给表格中单元格数据换行
		nowrap : false,
		checkOnSelect : false,
		//selectOnCheck : true,
		//emptyTips : "没有相关数据...",
		//idField : 'id', //主键
		columns:[[
					/* {field:'ck',checkbox:true,align:'center'}, */
					{field:'name',title:'流程名称',align:'center'},
					{field:'key',title:'操作',align:'center',formatter:function(value, rowData, rowIndex){
						return "<a href='#' onclick='initProcessByKey("+ value +")'>启动流程</a>";
					}}
					
				]]
	});
	
});
function initProcessByKey(key){
	$.ajax({
		url:'',
	});
}
</script>
</body>
</html>